<extend name="Public:base"/>

<block name="main">
<div id="yzh-content" class="col-xs-12">
    <div class="main-title">
        <h2>信息管理</h2>
    </div>

    <div class="table-actions">
    <if condition="$Think.const.environment == 'development'">
        <a class="btn btn-sm btn-primary" href="{:U('Block/add')}">添加碎片</a>
    </if>
    </div>

    <form id="myform" name="myform" action="{:U('Type/listorder')}" method="post">
        <table class="table table-hover table-condensed table-bordered">
            <thead>
                <tr>
                    <th width="20">ID</th>
                    <th align="left">{:L('name')}</th>
                    <th class="center table-cell-2">{:L('manage')}</th>
                </tr>
            </thead>
            <tbody>
                <volist name="list" id="vo" key="k">
                <tr>
                    <td align='center'>{$vo['id']}</td>
                    <td>{$vo['name']}</td>
                    <td align="center">
                    <a class="btn btn-xs btn-primary" href="{:U('Block/edit',array(id=>$vo['id'],pos=>$vo['pos']))}">编辑</a>
                    <a class="btn btn-xs btn-danger" href="javascript:confirm_delete('{:U('Block/delete',array(id=>$vo['id']))}')">删除</a>
                    </td>
                </tr>
                </volist>
            </tbody>
        </table>
    </form>

</div>

</block>